
package gov.chinatax.ctcps.generator.form;

import java.text.SimpleDateFormat;

import javax.servlet.http.HttpServletRequest;

import org.apache.struts.action.ActionError;
import org.apache.struts.action.ActionErrors;
import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionMapping;

/**
 * Form for nzjzGsjy.
 *
 * @author <a href="http://boss.bekk.no/boss/middlegen/"/>Middlegen</a>
 *
 * @struts.form name="nzjzGsjyForm"
 */
public class NzjzGsjyForm extends ActionForm {

   private final static SimpleDateFormat FORMAT = new SimpleDateFormat("dd.MM.yyyy hh:mm:ss");

   private java.lang.String _jybh = null;
   private java.lang.String _nd = null;
   private java.lang.String _zffsDm = null;
   private java.lang.String _yszbbh = null;
   private java.lang.String _xmbh = null;
   private java.math.BigDecimal _ysje = null;
   private java.math.BigDecimal _zcje = null;
   private java.math.BigDecimal _jhpfje = null;
   private java.math.BigDecimal _gssnjyje = null;
   private java.math.BigDecimal _gsjyje = null;
   private java.math.BigDecimal _gsjzxnje = null;
   private java.lang.String _dwbh = null;
   private java.lang.String _hzsjBz = null;
   private java.lang.String _jyztbh = null;
   private java.lang.String _sx = null;
   private java.lang.String _zt1 = null;
   private java.lang.String _zt2 = null;
   private java.math.BigDecimal snzcje = null;
   /**
    * Standard constructor.
    */
   public NzjzGsjyForm() {
   }

   /**
    * Returns the jybh
    *
    * @return the jybh
    */
   public java.lang.String getJybh() {
      return _jybh;
   }

   /**
    * Sets the jybh
    *
    * @param jybh the new jybh value
    */
   public void setJybh(java.lang.String jybh) {
      _jybh = jybh;
   }
   /**
    * Returns the nd
    *
    * @return the nd
    */
   public java.lang.String getNd() {
      return _nd;
   }

   /**
    * Sets the nd
    *
    * @param nd the new nd value
    */
   public void setNd(java.lang.String nd) {
      _nd = nd;
   }
   /**
    * Returns the zffsDm
    *
    * @return the zffsDm
    */
   public java.lang.String getZffsDm() {
      return _zffsDm;
   }

   /**
    * Sets the zffsDm
    *
    * @param zffsDm the new zffsDm value
    */
   public void setZffsDm(java.lang.String zffsDm) {
      _zffsDm = zffsDm;
   }
   /**
    * Returns the yszbbh
    *
    * @return the yszbbh
    */
   public java.lang.String getYszbbh() {
      return _yszbbh;
   }

   /**
    * Sets the yszbbh
    *
    * @param yszbbh the new yszbbh value
    */
   public void setYszbbh(java.lang.String yszbbh) {
      _yszbbh = yszbbh;
   }
   /**
    * Returns the xmbh
    *
    * @return the xmbh
    */
   public java.lang.String getXmbh() {
      return _xmbh;
   }

   /**
    * Sets the xmbh
    *
    * @param xmbh the new xmbh value
    */
   public void setXmbh(java.lang.String xmbh) {
      _xmbh = xmbh;
   }
   /**
    * Returns the ysje
    *
    * @return the ysje
    */
   public java.math.BigDecimal getYsje() {
      return _ysje;
   }

   /**
    * Sets the ysje
    *
    * @param ysje the new ysje value
    */
   public void setYsje(java.math.BigDecimal ysje) {
      _ysje = ysje;
   }
   /**
    * Returns the zcje
    *
    * @return the zcje
    */
   public java.math.BigDecimal getZcje() {
      return _zcje;
   }

   /**
    * Sets the zcje
    *
    * @param zcje the new zcje value
    */
   public void setZcje(java.math.BigDecimal zcje) {
      _zcje = zcje;
   }
   /**
    * Returns the jhpfje
    *
    * @return the jhpfje
    */
   public java.math.BigDecimal getJhpfje() {
      return _jhpfje;
   }

   /**
    * Sets the jhpfje
    *
    * @param jhpfje the new jhpfje value
    */
   public void setJhpfje(java.math.BigDecimal jhpfje) {
      _jhpfje = jhpfje;
   }
   /**
    * Returns the gssnjyje
    *
    * @return the gssnjyje
    */
   public java.math.BigDecimal getGssnjyje() {
      return _gssnjyje;
   }

   /**
    * Sets the gssnjyje
    *
    * @param gssnjyje the new gssnjyje value
    */
   public void setGssnjyje(java.math.BigDecimal gssnjyje) {
      _gssnjyje = gssnjyje;
   }
   /**
    * Returns the gsjyje
    *
    * @return the gsjyje
    */
   public java.math.BigDecimal getGsjyje() {
      return _gsjyje;
   }

   /**
    * Sets the gsjyje
    *
    * @param gsjyje the new gsjyje value
    */
   public void setGsjyje(java.math.BigDecimal gsjyje) {
      _gsjyje = gsjyje;
   }
   /**
    * Returns the gsjzxnje
    *
    * @return the gsjzxnje
    */
   public java.math.BigDecimal getGsjzxnje() {
      return _gsjzxnje;
   }

   /**
    * Sets the gsjzxnje
    *
    * @param gsjzxnje the new gsjzxnje value
    */
   public void setGsjzxnje(java.math.BigDecimal gsjzxnje) {
      _gsjzxnje = gsjzxnje;
   }
   /**
    * Returns the dwbh
    *
    * @return the dwbh
    */
   public java.lang.String getDwbh() {
      return _dwbh;
   }

   /**
    * Sets the dwbh
    *
    * @param dwbh the new dwbh value
    */
   public void setDwbh(java.lang.String dwbh) {
      _dwbh = dwbh;
   }
   /**
    * Returns the hzsjBz
    *
    * @return the hzsjBz
    */
   public java.lang.String getHzsjBz() {
      return _hzsjBz;
   }

   /**
    * Sets the hzsjBz
    *
    * @param hzsjBz the new hzsjBz value
    */
   public void setHzsjBz(java.lang.String hzsjBz) {
      _hzsjBz = hzsjBz;
   }
   /**
    * Returns the jyztbh
    *
    * @return the jyztbh
    */
   public java.lang.String getJyztbh() {
      return _jyztbh;
   }

   /**
    * Sets the jyztbh
    *
    * @param jyztbh the new jyztbh value
    */
   public void setJyztbh(java.lang.String jyztbh) {
      _jyztbh = jyztbh;
   }
   /**
    * Returns the sx
    *
    * @return the sx
    */
   public java.lang.String getSx() {
      return _sx;
   }

   /**
    * Sets the sx
    *
    * @param sx the new sx value
    */
   public void setSx(java.lang.String sx) {
      _sx = sx;
   }
   /**
    * Returns the zt1
    *
    * @return the zt1
    */
   public java.lang.String getZt1() {
      return _zt1;
   }

   /**
    * Sets the zt1
    *
    * @param zt1 the new zt1 value
    */
   public void setZt1(java.lang.String zt1) {
      _zt1 = zt1;
   }
   /**
    * Returns the zt2
    *
    * @return the zt2
    */
   public java.lang.String getZt2() {
      return _zt2;
   }

   /**
    * Sets the zt2
    *
    * @param zt2 the new zt2 value
    */
   public void setZt2(java.lang.String zt2) {
      _zt2 = zt2;
   }


   public java.math.BigDecimal getSnzcje() {
		return snzcje;
   }
	
	public void setSnzcje(java.math.BigDecimal snzcje) {
		this.snzcje = snzcje;
	}

/**
    * Validate the properties that have been set from this HTTP request,
    * and return an <code>ActionErrors</code> object that encapsulates any
    * validation errors that have been found.  If no errors are found, return
    * <code>null</code> or an <code>ActionErrors</code> object with no
    * recorded error messages.
    *
    * @param mapping The mapping used to select this instance
    * @param request The servlet request we are processing
    */
   public ActionErrors validate(ActionMapping mapping, HttpServletRequest request) {
      ActionErrors errors = new ActionErrors();
      // test for nullity
      if(getJybh() == null) {
         errors.add("jybh", new ActionError("error.jybh.required"));
      }
      if(getNd() == null) {
         errors.add("nd", new ActionError("error.nd.required"));
      }
      if(getZffsDm() == null) {
         errors.add("zffsDm", new ActionError("error.zffsDm.required"));
      }
      if(getYszbbh() == null) {
         errors.add("yszbbh", new ActionError("error.yszbbh.required"));
      }
      if(getYsje() == null) {
         errors.add("ysje", new ActionError("error.ysje.required"));
      }
      if(getZcje() == null) {
         errors.add("zcje", new ActionError("error.zcje.required"));
      }
      if(getJhpfje() == null) {
         errors.add("jhpfje", new ActionError("error.jhpfje.required"));
      }
      if(getGssnjyje() == null) {
         errors.add("gssnjyje", new ActionError("error.gssnjyje.required"));
      }
      if(getGsjyje() == null) {
         errors.add("gsjyje", new ActionError("error.gsjyje.required"));
      }
      if(getGsjzxnje() == null) {
         errors.add("gsjzxnje", new ActionError("error.gsjzxnje.required"));
      }
      if(getDwbh() == null) {
         errors.add("dwbh", new ActionError("error.dwbh.required"));
      }
      if(getHzsjBz() == null) {
         errors.add("hzsjBz", new ActionError("error.hzsjBz.required"));
      }
      if(getJyztbh() == null) {
         errors.add("jyztbh", new ActionError("error.jyztbh.required"));
      }
      // TODO test format/data
      return errors;
   }
}
